package org.ligson.springboot.simple;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class UserController {

    private final UserService userService;

    public UserController(UserService userService) {
        this.userService = userService;
    }

    @GetMapping("/user")
    public User user() {
        return userService.findByUserName("test");
    }

    @GetMapping("/add")
    public void add(int n){

    }
}
